diff --git a/view/include/head.php b/view/include/head.php index 660089532..d0d939d07 100644 --- a/view/include/head.php +++ b/view/include/head.php @@ -1,186 +1,188 @@ getId()); } $custom = array(); if (file_exists($extraPluginFile) && AVideoPlugin::isEnabled("c4fe1b83-8f5a-4d1b-b912-172c608bf9e3")) { require_once $extraPluginFile; $ec = new ExtraConfig(); $custom[] = $ec->getDescription(); } if (!empty($poster)) { $subTitle = str_replace(array('"', "\n", "\r"), array("", "", ""), strip_tags($video['description'])); $custom = array(); $custom[] = $subTitle; - $custom[] = $video["category"]; + if(!empty($video["category"])){ + $custom[] = $video["category"]; + } } if (!empty($_GET['catName'])) { $category = Category::getCategoryByName($_GET['catName']); $description = str_replace(array('"', "\n", "\r"), array("", "", ""), strip_tags($category['description'])); $custom = array(); $custom[] = $description; $custom[] = $category['name']; } foreach ($custom as $key => $value) { if(empty($value)){ unset($custom[$key]); } } if(!empty($metaDescription)){ $metaDescription = implode(" - ", $custom)." - {$metaDescription}"; }else{ $metaDescription = implode(" - ", $custom); } // for SEO to not rise an error of duplicated title or description of same pages with and without last slash $metaDescription .= getSEOComplement(array("addAutoPrefix" => false)); $theme = getCurrentTheme(); if(empty($config)){ $config = new Configuration(); } ?> keywords)); ?>"> showCustomCSS) && file_exists($filename)){ echo ''; }else{ if($theme !== "default"){ echo ""; } if(empty($customizePlugin->showCustomCSS)){ echo ""; } if(!file_exists($filename)){ echo ""; } echo ''; } $cssFiles = array(); $cssFiles[] = "view/css/main.css"; $cssFiles = array_merge($cssFiles, AVideoPlugin::getCSSFiles()); $cssURL = combineFiles($cssFiles, "css"); ?> getDisable_analytics()) { ?> getHead(); echo $head; if (!empty($video)) { if (!empty($video['users_id'])) { $userAnalytics = new User($video['users_id']); echo $userAnalytics->getAnalytics(); unset($userAnalytics); } } ogSite(); ?> \ No newline at end of file